<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8">
<title>网投彩票管理系统</title>
<link rel="stylesheet" type="text/css" href="__SYSMET__/template/css/base.css" />
<link rel="stylesheet" type="text/css" href="__SYSMET__/template/css/admin1.css" />
<style type="text/css">
.demo{width:500px; margin:20px auto}
h3{height:28px; line-height:28px;font-size:14px}
.demo p{height:32px; line-height:32px; position:relative}
.demo p img{position:absolute; top:4px; left:125px; cursor:pointer;position:relative;left:30px;}
.demo p img#getcode_zh{width:150px; height:50px; z-index:1001;}
.input{width:68px; height:20px; line-height:20px; padding:1px; border:1px solid #d3d3d3}
.btn{width:60px;height:26px; margin-left:48px; background:url(btn_bg.gif) repeat-x; border:1px solid #ccc; cursor:pointer}
</style>
</head>
<body>

<div class="login">
	<h1></h1>
    <div class="login_con">
    	<p class="login_title" style="padding-bottom:10px;">网投彩票管理系统【智能版】</p>
   <form method='post' action='' id="login">    
            <ul class="clearfix">
                <li>
                    <label>用户名：</label>
                    <input type="text" name="nickname" id="username"/>
                </li>
                <li>
                    <label>密码：</label>
                    <input type="password" name="password" id="password"/>
                </li>
            </ul>
            <div class="login_btn">
                <input type="submit" name="do" value=""/>
            </div>
        </form>
		<div style="width:400px; padding-top:20px; text-align: center;color:#FF0000"></div>
    </div>
</div>
<script type="text/javascript" src="__SYSMET__/lib/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="__SYSMET__/lib/layer/2.4/layer.js"></script>
<script type="text/javascript">
	$("#login").submit(function(){
		var username = $("#username").val();
		var password = $("#password").val();
		if(username == ''){
			layer.msg('请输入用户名!', {icon: 5});
			return false;
		}else if(password == ''){
			layer.msg('请输入密码!', {icon: 5});
			return false;
		}
		$.post(
			'/admin/login/login',
			$(this).serialize(),
			function(data){
				if(data.code == 0){
					layer.msg(data.msg, {icon: 5});
					return false;
				}else{
					window.location.href=data.url;
				}
				
			},'json'
		);
		return false;
	})
</script>
</body>
</html>
